class @AdminBookRoutes extends Backbone.Router

    routes:
        "Books/Create": "Create"
        "Books/Edit*path": "Edit"
        "Books/Listing*path": "Listing"
        "Books/Index": "Listing"
        "Books": "Listing"

    Create: ->
        model = new AdminBookCreateModel()
        view = new AdminBookCreateView({ model: model })
        view.render()

    Edit: (path) ->
        model = new AdminBookEditModel()
        model.set("BookId", Url.GetParameterByName("BookId"))
        view = new AdminBookEditView({ model: model })

    Listing: ->
        model = new AdminBookListingModel()
        model.FillModelFromUrl()
        view = new AdminBookListingView({ model: model })